back to index.

spawsh - A Gemini TUI

I've been spending some more time working on spawsh, my gemini browser, in the evenings after work. To begin with, spawsh was a very barebones, incredibly spartan, and not very command line friendly. There was no way to scroll without scrolling the whole terminal. It didn't really sit right with me, and I've been spending more and more time in the terminal as I get used to working pretty much solely there with work.

With that said, I was looking into various options for curses-like libraries for .net. What's out there is super heavy, and doesn't really fit with what I want. I want to include a single file in my project, just give me a basic interface and let me control things. What's out there really isn't that. So I made a very hacky attempt at a TUI.

Making liberal use of VT100 escape sequences, I've made a very basic interactive TUI, no buttons or widgets, just status bars, and a central pane for the content. Let's have a look at what we ended up with:

As you can see, this is miles ahead of where spawsh was six months ago when I parked it. There's a much better sense of an actual applicatin as opposed to a dumb terminal that just dumps loads of stuff into your console history. I've been using spawsh as I developed it over the past week daily on my pinebook. Really helped me figure out what the rough spots are for my usage, and I feel it's at a perfect stage for people to use it.

There are definitely some issues still surrounding the size of the executable created, it's weighing in about 70mb when I package it up for arm64, which is a lot for a very simple text application. The overhead of .net, but what can you do. I've been using Vala a bit recently in my contributions to Elementary, and the transpilation to C and then compilation from there really gives a much better output experience, with file sizes being much more sane, and compilation actually being about equal if not faster for what I'm doing. It's something to consider as I'm migrating more and more of my day to day usage away from windows - the language is comfortable, and the distribution is easier, what's not to like?


Comment